<?php
/**
 * $Id: external.php 71 2008-12-25 07:28:33Z gpo_gigapromoters $
 * 
 * This file can not be redistributed to anyone without the permission of Giga Promoters
 * Copyright 2005 - 2008, Giga Promoters
 * 						  608 Aggarwal Cyber Plaza
 *						  Netaji Subhash Place, Delhi - 110034
 *						  www.gigapromoters.com
 * 
 *
 * This is parent of parent class of a controller and should not be edited ever without permission.
 * @version 			$Rev: 71 $
 * @lastModifiedBy		$LastChangedBy: gpo_gigapromoters $
 * @lastChanged			$Date: 2008-12-25 12:58:33 +0530 (Thu, 25 Dec 2008) $
 * @copyright 			Giga Promoters (www.gigapromoters.com)
 * 
 */

/**
 * Experimental behavior for dynamic associations
 *
 */
class ExternalBehavior extends ModelBehavior {
	
	var $model;

	function setup(&$model) {

		// bind models here
		$assoc = Configure::read($model->name.'.assoc');
		if($assoc)
		{
			$model->bindModel($assoc, false);
		}
		/* Multiple biding case
		elseif(is_array($assoc))
		{
			foreach($assoc as $singleAssoc)
			{
				$model->bindModel($singleAssoc, false);
			}
		}*/
	}
	

}
?>